Nowadays, Personal Video Recorder (PVR) applications in set top boxes are widely used. Users sometimes need to edit their video records, for example, they need to delete a file to remove commercials. However, the commercials may be located anywhere in the video records, so the users may need to delete data from anywhere in the video record files. That is, the users may need to remove the commercials from the beginning, the middle, or the end of the video record files.
FIG. 1 is an example of a traditional file system, such as FAT 32 or EXT 2. In this file system, a file usually is stored in plurality of blocks. In FIG. 1, 10 blocks are used to store the file. A block is the smallest allocation unit, and contains 16 sectors. There are 512 bytes in a sector, so the size of a block usually is 8K bytes. In a sequential file, all blocks are linked together by the file management system. For each block, the link information may comprise the previous index, e.g. the number of the block coming before the current block, and the next index, e.g. the number of the block coming after the current block. Usually the file management system knows where a file starts, i.e. the number of the starting block, and the length of space which is occupied by the file, i.e. how many blocks are used to store this file. The real length of the file may be less than the length of the space occupied by the file.
In this traditional file system, it is easy to delete data from the end of the file, e.g. to remove commercials. If the file is deleted at its end, the deleted data will be released directly. However, it is difficult data from middle of the file, especially from parts of some blocks. If data is removed from part of the block, the block will not be a full one (non-full), i.e. there will be less than 8K of data in the block. In this condition, the traditional process method is to shift the data in the following blocks to fill the non-full block. The reason is that in the traditional file system, the file management system only registers the number of the starting block and the length of the file (i.e. how many blocks are used to store the file), so even some data has been removed from a block, some time will be taken to try to read out this part of the block. However, to shift the following blocks to fill the non-full block will take processing time, especially for a file with large size.
To solve problems existing in the traditional file system, JP 2003 052006 discloses an information editing controller for realizing high-speed editing by reducing a copy operation accompanied by read/write access to a medium in editing video and audio data.